Data
basic EDA
## x y LOCAL_DATE TOTAL_PRECIPITATION
## Min. :-122.8 Min. :53.83 Length:31470 Min. : 0.000
## 1st Qu.:-122.7 1st Qu.:53.89 Class :character 1st Qu.: 0.000
## Median :-122.7 Median :53.89 Mode :character Median : 0.000
## Mean :-122.7 Mean :53.89 Mean : 1.611
## 3rd Qu.:-122.7 3rd Qu.:53.89 3rd Qu.: 1.600
## Max. :-122.7 Max. :53.89 Max. :50.000
## NA's :223
## STATION_NAME MAX_TEMPERATURE MIN_TEMPERATURE TOTAL_RAIN
## Length:31470 Min. :-36.900 Min. :-50.000 Min. : 0.000
## Class :character 1st Qu.: 2.200 1st Qu.: -6.100 1st Qu.: 0.000
## Mode :character Median : 10.200 Median : -0.300 Median : 0.000
## Mean : 9.575 Mean : -1.742 Mean : 1.152
## 3rd Qu.: 18.300 3rd Qu.: 5.400 3rd Qu.: 0.500
## Max. : 38.900 Max. : 20.700 Max. :50.000
## NA's :78 NA's :62 NA's :4989
## MIN_REL_HUMIDITY LOCAL_YEAR LOCAL_MONTH MEAN_TEMPERATURE
## Min. : 11.00 Min. :1940 Min. : 1.00 Min. :-41.500
## 1st Qu.: 37.00 1st Qu.:1958 1st Qu.: 4.00 1st Qu.: -1.800
## Median : 51.50 Median :1980 Median : 7.00 Median : 5.000
## Mean : 53.09 Mean :1980 Mean : 6.52 Mean : 3.924
## 3rd Qu.: 69.00 3rd Qu.:2001 3rd Qu.:10.00 3rd Qu.: 12.000
## Max. :100.00 Max. :2024 Max. :12.00 Max. : 26.900
## NA's :23066 NA's :87
## Mode NA's
## logical 1
## [1] NA
## x y LOCAL_DATE TOTAL_PRECIPITATION
## Min. :-122.8 Min. :53.83 Length:31470 Min. : 0.000
## 1st Qu.:-122.7 1st Qu.:53.89 Class :character 1st Qu.: 0.000
## Median :-122.7 Median :53.89 Mode :character Median : 0.000
## Mean :-122.7 Mean :53.89 Mean : 1.611
## 3rd Qu.:-122.7 3rd Qu.:53.89 3rd Qu.: 1.600
## Max. :-122.7 Max. :53.89 Max. :50.000
## NA's :223
## STATION_NAME MAX_TEMPERATURE MIN_TEMPERATURE TOTAL_RAIN
## Length:31470 Min. :-36.900 Min. :-50.000 Min. : 0.000
## Class :character 1st Qu.: 2.200 1st Qu.: -6.100 1st Qu.: 0.000
## Mode :character Median : 10.200 Median : -0.300 Median : 0.000
## Mean : 9.575 Mean : -1.742 Mean : 1.152
## 3rd Qu.: 18.300 3rd Qu.: 5.400 3rd Qu.: 0.500
## Max. : 38.900 Max. : 20.700 Max. :50.000
## NA's :78 NA's :62 NA's :4989
## MIN_REL_HUMIDITY LOCAL_YEAR LOCAL_MONTH MEAN_TEMPERATURE
## Min. : 11.00 Min. :1940 Min. : 1.00 Min. :-41.500
## 1st Qu.: 37.00 1st Qu.:1958 1st Qu.: 4.00 1st Qu.: -1.800
## Median : 51.50 Median :1980 Median : 7.00 Median : 5.000
## Mean : 53.09 Mean :1980 Mean : 6.52 Mean : 3.924
## 3rd Qu.: 69.00 3rd Qu.:2001 3rd Qu.:10.00 3rd Qu.: 12.000
## Max. :100.00 Max. :2024 Max. :12.00 Max. : 26.900
## NA's :23066 NA's :87
check temp dist for in a random day from all year value
## STATION_NAME
## 1 PRINCE GEORGE A
## 2 PRINCE GEORGE
get 90th from the all year for all day value
Plot
EHF plot

plot all year temp in grey vs baseline
## Warning: Removed 396 rows containing missing values or values outside the scale range
## (`geom_line()`).
## Warning: Removed 1 row containing missing values or values outside the scale range
## (`geom_line()`).
## Removed 1 row containing missing values or values outside the scale range
## (`geom_line()`).

## Warning: Removed 395 rows containing missing values or values outside the scale range
## (`geom_line()`).
## Warning: Removed 2 rows containing missing values or values outside the scale range
## (`geom_line()`).
## Warning: Removed 1 row containing missing values or values outside the scale range
## (`geom_line()`).

Analyze the hw
hw dist for certain 1 year
prepare for the data
## # A tibble: 24 × 7
## Month Day Percentile_90 MAX_TEMP_YEAR DayOfYear Condition Cumulative_Count
## <int> <int> <dbl> <dbl> <dbl> <lgl> <dbl>
## 1 1 11 4.31 5.5 11 TRUE 1
## 2 1 12 4.52 5.5 12 TRUE 2
## 3 1 27 4.4 5 27 TRUE 1
## 4 3 17 10 11.2 76 TRUE 1
## 5 3 18 10 12.1 77 TRUE 2
## 6 3 19 10 14 78 TRUE 3
## 7 3 20 10.0 15.7 79 TRUE 4
## 8 3 21 10.0 15.7 80 TRUE 5
## 9 3 22 10.4 14.5 81 TRUE 6
## 10 5 9 21.1 25 129 TRUE 1
## # ℹ 14 more rows
plot hw analysis for all year
plot overall count of hw through years


seperate view of the heatmap
examine specific year
Plot EHF vs Percentile_90 for specific year
1941
1958
1969
1993
2022